﻿using System;
using System.Windows.Input;
using TestBat.IViewModels.Dialogs;
using TestBat.ViewModels.Base;

namespace TestBat.ViewModels.Dialogs
{
    public abstract class DialogViewModel : ViewModel, IDialogViewModel
    {
        public event EventHandler CloseEvent;

        public abstract ICommand CloseCommand { get; }

        protected void InvokeCloseEvent()
        {
            if (CloseEvent != null)
                CloseEvent(this, EventArgs.Empty);
        }
    }
}
